package com.artron.mediaartron.ui.adapter;

import android.support.v4.app.FragmentManager;
import android.support.v4.app.FragmentPagerAdapter;

import com.artron.baselib.base.BaseFragment;
import com.artron.mediaartron.base.BaseFragmentPagerAdapter;
import com.artron.mediaartron.ui.fragment.factory.HomeFragmentFactory;


/**
 * Class description here
 *
 * @author doing
 * @version 1.0.0
 * @since 2017-07-17.
 */

public class HomePagerAdapter extends BaseFragmentPagerAdapter {

    private int mSize;

    public HomePagerAdapter(FragmentManager fm, int size) {
        super(fm);
        this.mSize = size;
    }

    @Override
    public BaseFragment getItem(int position) {
        return HomeFragmentFactory.getInstance().getFragment(position);
    }

    @Override
    public int getCount() {
        return mSize;
    }

}
